package com.micro.ai.agents.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.v3.oas.annotations.media.Schema;
import lombok.Data;

import java.io.Serializable;
import java.time.LocalDateTime;

/**
 * 智能体版本历史实体类
 * 
 * @author micro-ai
 * @since 0.0.1
 */
@Data
@TableName("agent_versions")
@Schema(description = "智能体版本信息")
public class AgentVersion implements Serializable {

    private static final long serialVersionUID = 1L;

    @TableId(value = "id", type = IdType.ASSIGN_ID)
    @Schema(description = "版本ID", example = "version_123456789")
    private String id;

    @Schema(description = "智能体ID", example = "agent_123")
    private String agentId;

    @Schema(description = "版本号", example = "1.0.1")
    private String version;

    @Schema(description = "配置快照（JSON）")
    private String configSnapshot;

    @Schema(description = "变更日志", example = "修复了已知bug，优化了响应速度")
    private String changeLog;

    @Schema(description = "创建人ID", example = "user_001")
    private String createdBy;

    @TableField(fill = FieldFill.INSERT)
    @Schema(description = "创建时间")
    private LocalDateTime createdAt;
}

